﻿<%@ Page Language="C#" MasterPageFile="~/Globals/GenericMasterPage.master" AutoEventWireup="true" CodeFile="ABMPedidosProveedor.aspx.cs" Inherits="Modules_Compras_ABMPedidosProveedor" Title="Untitled Page" %>

<%@ Register Assembly="WebUtils" Namespace="WebUtils.Controls" TagPrefix="cc2" %>

<%@ Register Src="../../Controls/TecnoPezPopUp.ascx" TagName="TecnoPezPopUp" TagPrefix="uc3" %>
<%@ Register Src="../../Controls/TecnoPezCalendar.ascx" TagName="TecnoPezCalendar"
    TagPrefix="uc4" %>

<%@ Register Src="../../Controls/TecnopezDataGRIDABMView.ascx" TagName="TecnopezDataGRIDABMView"
    TagPrefix="uc2" %>

<%@ Register Src="../../Controls/TecnoPezUpdateProgress.ascx" TagName="TecnoPezUpdateProgress"
    TagPrefix="uc1" %>

<%@ Register Assembly="Microsoft.Practices.EnterpriseLibrary.Validation.Integration.AspNet"
    Namespace="Microsoft.Practices.EnterpriseLibrary.Validation.Integration.AspNet"
    TagPrefix="cc1" %>
    
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="act" %>
<asp:Content ID="Content1" ContentPlaceHolderID="CPHPrincipal" Runat="Server">
    <asp:Wizard ID="wzrABM" runat="server" ActiveStepIndex="1" BorderColor="#B5C7DE"
        BorderWidth="0px" DisplaySideBar="False" Font-Names="Verdana" Font-Size="0.8em">
        <StepStyle Font-Size="0.8em" ForeColor="#333333" VerticalAlign="Top" />
        <SideBarStyle BackColor="#507CD1" Font-Size="0.9em" VerticalAlign="Top" />
        <NavigationButtonStyle BackColor="White" BorderColor="#507CD1" BorderStyle="Solid"
            BorderWidth="1px" Font-Names="Verdana" Font-Size="0.8em" ForeColor="#284E98" />
        <WizardSteps>
            <asp:WizardStep ID="wzrBusqueda" runat="server" StepType="Complete" Title="Busqueda">
                <table id="Table1" cellspacing="0" style="width: 100%">
                    <tr>
                        <td class="cabeceraTabla" colspan="3">
                            Buscar Pedidos de Proveedores</td>
                    </tr>
                    <tr>
                        <td class="columnaLabels" style="width: 200px">
                            <asp:Label ID="lblBuscarCodigo" runat="server" Text="C&#243;digo" Width="200px"></asp:Label>
                        </td>
                        <td class="columnaData" style="width: 210px">
                            <asp:TextBox ID="txtBuscarCodigo" runat="server" Width="200px"></asp:TextBox>
                        </td>
                        <td rowspan="2" valign="top">
                            <asp:Button ID="cmdBuscar" runat="server" BorderStyle="None" CssClass="Boton" Height="23px"
                                Text="Buscar" Width="102px" />
                            <asp:Button ID="cmdNuevo" runat="server" CssClass="Boton" Height="23px" OnClick="cmdNuevo_Click"
                                Text="Nuevo" Width="102px" />
                        </td>
                    </tr>
                    <tr>
                        <td class="columnaLabels" style="width: 200px">
                            <asp:Label ID="Label14" runat="server" Text="Proveedor" Width="200px"></asp:Label>
                        </td>
                        <td class="columnaData" style="width: 210px">
                            <asp:DropDownList ID="ddlProveedor" runat="server">
                            </asp:DropDownList>
                        </td>
                    </tr>
                    <tr>
                        <td colspan="3">
                            <br />
                            <br />
                            <uc2:TecnopezDataGRIDABMView ID="grdPedidosProveedor" runat="server" />
                        </td>
                    </tr>
                </table>
            </asp:WizardStep>
            <asp:WizardStep ID="wzrEdicion" runat="server" StepType="Complete" Title="Edicion">
                <table cellspacing="0" width="100%">
                    <tr>
                        <td class="cabeceraTabla" colspan="4" style="height: 20px">
                            Datos del Pedido</td>
                    </tr>
                    <tr>
                        <td class="columnaLabels" style="width: 250px; height: 26px">
                            <asp:Label ID="Label1" runat="server" Text="C&#243;digo" Width="200px"></asp:Label>
                        </td>
                        <td class="columnaData" style="width: 205px; height: 26px">
                            <asp:TextBox ID="txtID" runat="server" Width="200px"></asp:TextBox>
                        </td>
                        <td class="columnaData" style="width: 1px; height: 26px">
                            &nbsp;</td>
                        <td rowspan="4" style="width: 7px" valign="top">
                            <asp:Button ID="cmdEditar" runat="server" CausesValidation="False" CssClass="Boton"
                                Height="23px" OnClick="cmdEditar_Click" Text="Editar" Width="102px" />
                            <asp:Button ID="cmdEliminar" runat="server" CausesValidation="False" CssClass="Boton"
                                Height="23px" OnClick="cmdEliminar_Click" Text="Eliminar" Width="102px" />
                            &nbsp;<br />
                        </td>
                    </tr>
                    <tr>
                        <td class="columnaLabels" style="width: 200px">
                            <asp:Label ID="Label4" runat="server" Text="Utilizar oferta" Width="200px"></asp:Label>
                        </td>
                        <td class="columnaData" style="width: 205px">
                            <uc3:TecnoPezPopUp ID="TPPOferta" runat="server" DoPostBack="true" />
                        </td>
                        <td class="columnaData" style="width: 1px">
                        </td>
                    </tr>
                    <tr>
                        <td class="columnaLabels" style="width: 200px">
                            <asp:Label ID="Label2" runat="server" Text="Proveedor" Width="200px"></asp:Label>
                        </td>
                        <td class="columnaData" style="width: 205px">
                            <uc3:TecnoPezPopUp ID="TPPProveedor" runat="server" />
                        </td>
                        <td class="columnaData" style="width: 1px">
                            &nbsp;</td>
                    </tr>
                    <tr>
                        <td class="columnaLabels" style="width: 200px" valign="top">
                            <asp:Label ID="Label3" runat="server" Text="Fecha Carga" Width="200px"></asp:Label>
                        </td>
                        <td class="columnaData" style="width: 205px" valign="top">
                            <cc2:tecnopezcalendar id="TPCFechaCarga" runat="server" text=""></cc2:tecnopezcalendar>
                        </td>
                        <td class="columnaData" style="width: 1px" valign="top">
                            &nbsp;</td>
                    </tr>
                    <tr>
                        <td class="columnaLabels" style="width: 200px" valign="top">
                            <asp:Label ID="Label5" runat="server" Text="Empleado" Width="200px"></asp:Label>
                        </td>
                        <td class="columnaData" style="width: 205px" valign="top">
                            <asp:TextBox ID="txtEmpleado" runat="server" Width="200px"></asp:TextBox>
                        </td>
                        <td class="columnaData" style="width: 1px" valign="top">
                            &nbsp;</td>
                        <td style="width: 7px" valign="bottom">
                        </td>
                    </tr>
                    <tr>
                        <td class="columnaLabels" style="width: 200px" valign="top">
                            <asp:Label ID="Label6" runat="server" Text="Estado" Width="200px"></asp:Label>
                        </td>
                        <td class="columnaData" style="width: 205px" valign="top">
                            <asp:TextBox ID="txtEstado" runat="server" Width="200px"></asp:TextBox>
                        </td>
                        <td class="columnaData" style="width: 1px" valign="top">
                            &nbsp;</td>
                        <td style="width: 7px" valign="bottom">
                            &nbsp;
                        </td>
                    </tr>
                    <tr>
                        <td class="columnaLabels" style="width: 200px" valign="top">
                            <asp:Label ID="Label7" runat="server" Text="Moneda"></asp:Label>
                        </td>
                        <td class="columnaData" style="width: 205px" valign="top">
                            <uc3:TecnoPezPopUp ID="TPPTipoMoneda" runat="server" />
                        </td>
                        <td class="columnaData" style="width: 1px" valign="top">
                            &nbsp;</td>
                        <td rowspan="2" style="width: 7px" valign="bottom">
                            <asp:Button ID="btnAceptar" runat="server" CssClass="Boton" Height="23px" OnClick="btnAceptar_Click"
                                Text="Aceptar" Width="102px" />
                            <asp:Button ID="cmdCancelar" runat="server" CausesValidation="False" CssClass="Boton"
                                Height="23px" OnClick="cmdCancelar_Click" Text="Cancelar" Width="102px" />
                        </td>
                    </tr>
                    <tr>
                        <td class="columnaLabels" style="width: 200px" valign="top">
                            <asp:Label ID="Label8" runat="server" Text="Total"></asp:Label>
                        </td>
                        <td class="columnaData" style="width: 205px" valign="top">
                            <asp:TextBox ID="txtTotal" runat="server"></asp:TextBox>
                        </td>
                        <td class="columnaData" style="width: 1px" valign="top">
                            &nbsp;</td>
                    </tr>
                    <tr>
                        <td colspan="2" style="height: 25px" valign="top">
                            <asp:Label ID="_lblError" runat="server" CssClass="errorLabel"></asp:Label>
                            <br />
                            <cc1:PropertyProxyValidator ID="PPVProveedor" runat="server" Display="Dynamic" DisplayMode="List"
                                OnValueConvert="PPVProveedor_ValueConvert" RulesetName="" SetFocusOnError="True"></cc1:PropertyProxyValidator>
                        </td>
                        <td colspan="1" style="width: 1px; height: 25px" valign="top">
                        </td>
                        <td style="width: 7px; height: 25px" valign="top">
                        </td>
                    </tr>
                    <tr>
                        <td colspan="2" style="height: 25px" valign="top">
                            &nbsp;
                        </td>
                        <td colspan="1" style="width: 1px; height: 25px" valign="top">
                        </td>
                        <td style="width: 7px; height: 25px" valign="top">
                        </td>
                    </tr>
                    <tr>
                        <td class="cabeceraTabla" colspan="4" style="height: 20px" valign="top">
                            Detalle del Pedido</td>
                    </tr>
                    <tr>
                        <td class="columnaLabels" style="height: 25px" valign="top">
                            <asp:Label ID="Label9" runat="server" Text="Insumo"></asp:Label>
                        </td>
                        <td class="columnaData" style="height: 25px" valign="top">
                            <uc3:TecnoPezPopUp ID="TPPInsumo" runat="server" />
                        </td>
                        <td class="columnaData" colspan="1" style="width: 1px; height: 25px" valign="top">
                            &nbsp;</td>
                        <td style="width: 7px; height: 25px" valign="top">
                        </td>
                    </tr>
                    <tr>
                        <td class="columnaLabels" style="height: 25px" valign="top">
                            <asp:Label ID="Label10" runat="server" Text="Cantidad"></asp:Label>
                        </td>
                        <td class="columnaData" style="height: 25px" valign="top">
                            <asp:TextBox ID="txtCantidad" runat="server"></asp:TextBox>
                        </td>
                        <td class="columnaData" colspan="1" style="width: 1px; height: 25px" valign="top">
                            &nbsp;</td>
                        <td style="width: 7px; height: 25px" valign="top">
                        </td>
                    </tr>
                    <tr>
                        <td class="columnaLabels" style="height: 25px" valign="top">
                            <asp:Label ID="Label11" runat="server" Text="Precio"></asp:Label>
                        </td>
                        <td class="columnaData" style="height: 25px" valign="top">
                            <asp:TextBox ID="txtPrecio" runat="server"></asp:TextBox>
                        </td>
                        <td class="columnaData" colspan="1" style="width: 1px; height: 25px" valign="top">
                            &nbsp;</td>
                        <td style="width: 7px; height: 25px" valign="top">
                            <asp:Button ID="cmdAgregarDetalle" runat="server" CssClass="Boton" Height="23px"
                                OnClick="cmdAgregarDetalle_Click" Text="Agregar" Width="102px" />
                        </td>
                    </tr>
                    <tr>
                        <td class="columnaLabels" colspan="4" valign="top">
                            <asp:GridView ID="grdDetallePedido" runat="server" CellPadding="4" ForeColor="#333333"
                                GridLines="None" OnRowCommand="grdDetallePedido_RowCommand" Width="100%">
                                <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                                <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                                <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
                                <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
                                <EditRowStyle BackColor="#999999" />
                                <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
                                <PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
                            </asp:GridView>
                        </td>
                    </tr>
                    <tr>
                        <td colspan="4" valign="top">
                            <asp:Label ID="_lblErrorDetalle" runat="server" CssClass="errorLabel"></asp:Label>
                            <br />
                            <cc1:PropertyProxyValidator ID="PPVInsumo" runat="server" Display="Dynamic" DisplayMode="List"
                                OnValueConvert="PPVInsumo_ValueConvert" RulesetName="" SetFocusOnError="True"></cc1:PropertyProxyValidator>
                        </td>
                    </tr>
                </table>
            </asp:WizardStep>
        </WizardSteps>
        <SideBarButtonStyle BackColor="#507CD1" Font-Names="Verdana" ForeColor="White" />
        <HeaderStyle BackColor="#284E98" BorderColor="#EFF3FB" BorderStyle="Solid" BorderWidth="2px"
            Font-Bold="True" Font-Size="0.9em" ForeColor="White" HorizontalAlign="Center" />
    </asp:Wizard>
</asp:Content>